﻿<%@ page language="C#" masterpagefile="MasterPageFrame.master" autoeventwireup="true" inherits="admin_notetypelist, App_Web_bgx0xzll" title="信息管理 -> 信息分类" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
<style type="text/css">

    #showpageurl{width:380px}
</style>
<script type="text/javascript">
function __add()
{
	$form.reset("form0");
	$form.addOption("ParentTypeID","","请选择所属上级分类");
	$form.addOption("ParentTypeID","0","无上级分类");
	$form.addOptionsByXML("xmlnotetype.aspx","ParentTypeID","notetypeid","notetypename");

	__showdialog("添加信息分类");
}

function __delete(_notetypeid)
{
	if (confirm("您真的要删除此信息分类吗？"))
		location="notetypedelete.aspx?notetypeid="+_notetypeid;
}

function __modify(_notetypeid)
{
	$form.removeOptions("ParentTypeID");
	$form.addOption("ParentTypeID","","请选择所属上级分类");
	$form.addOption("ParentTypeID","0","无上级分类");
	$form.addOptionsByXML("xmlnotetype.aspx?exclude="+_notetypeid,"ParentTypeID","notetypeid","notetypename");
	__showdialog("修改信息分类");
	
	$form.ElementsDataFromXML("form0","xmlnotetype.aspx?notetypeid="+_notetypeid);
}
function __formcheck(event)
{
	if (!jsformcheck(event))
		return false;
	return true;
}

function __showdialog(_t)
{

	$('#dialog').dialog({
		autoOpen: false,
		width: 560,
		resizable:false,
		title:_t
	});

	$('#dialog').dialog('open');
}
</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <div class="caption">
        <a class="btn" id="btnAdd" onclick="javascript:__add();">添加分类</a>
    </div>
    <div id="notetypelist" runat="server">

    </div>
    <div id="dialog" title="" class="X-dialog">
	    <form name="form0" id="form0" action="notetypeupdate.aspx" method="post" onsubmit="javascript:return __formcheck(event);">
  	    <table border="0" cellspacing="0" cellpadding="0" width="100%">
    	    <tr>
	          <td class="WebNote_Field">上级分类</td>
	          <td><select size="1" name="ParentTypeID" id="ParentTypeID" style="margin-right:10px;font-size:9pt;width:180px" nullabled="false" alerttext="上级分类" ></select></td>
	        </tr>
	        <tr>
	          <td class="WebNote_Field">分类名称</td>
	          <td><input type="text" name="NoteTypeName" id="notetypename" maxlength="50" datatype="string" nullabled="false" alerttext="分类名称" autocomplete="off"></td>
	        </tr>
	        <tr>
	          <td class="WebNote_Field">显示页面</td>
	          <td><input type="text" name="showpageurl" id="showpageurl" maxlength="255" datatype="string" nullabled="true" alerttext="显示页面" autocomplete="off"></td>
	        </tr>
	        <tr>
	          <td class="WebNote_Field">排序号</td>
	          <td><input type="text" name="sortNum" id="sortNum" maxlength="255" datatype="number" nullabled="false" alerttext="排序号" autocomplete="off"></td>
	        </tr>
	        <tr flag="3">
	          <td class="WebNote_Field">是否锁定</td>
	          <td>
			    <input type="radio" name="islock" nullabled="false" alerttext="是否锁定" value="1">是
			    <input type="radio" name="islock" value="0">否
	          </td>
	        </tr>
    	    <tr>
	          <td></td>
	          <td>
			    <input type="hidden" name="notetypeid" id="notetypeid">
			    <input type="submit" value="提交">
	          </td>
	        </tr>
	    </table>
	    </form>
    </div>
</asp:Content>

